<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>File: extraction.rb</title>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  <meta http-equiv="Content-Script-Type" content="text/javascript" />
  <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
  <script type="text/javascript">
  // <![CDATA[

  function popupCode( url ) {
    window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
  }

  function toggleCode( id ) {
    if ( document.getElementById )
      elem = document.getElementById( id );
    else if ( document.all )
      elem = eval( "document.all." + id );
    else
      return false;

    elemStyle = elem.style;
    
    if ( elemStyle.display != "block" ) {
      elemStyle.display = "block"
    } else {
      elemStyle.display = "none"
    }

    return true;
  }
  
  // Make codeblocks hidden by default
  document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
  
  // ]]>
  </script>

</head>
<body>



  <div id="fileHeader">
    <h1>extraction.rb</h1>
    <table class="header-table">
    <tr class="top-aligned-row">
      <td><strong>Path:</strong></td>
      <td>extraction.rb
      </td>
    </tr>
    <tr class="top-aligned-row">
      <td><strong>Last Update:</strong></td>
      <td>Thu Jun 14 12:58:33 India Standard Time 2007</td>
    </tr>
    </table>
  </div>
  <!-- banner header -->

  <div id="bodyContent">



  <div id="contextContent">

    <div id="description">
      <p>
These methods will be used in the extraction phase. This method
prepopulates the config templates for both the extract and loading process
based on the parameter sent.
</p>

    </div>


   </div>

    <div id="method-list">
      <h3 class="section-bar">Methods</h3>

      <div class="name-list">
      <a href="#M000030">extract_tables</a>&nbsp;&nbsp;
      <a href="#M000031">extract_tables_to_fixed_width</a>&nbsp;&nbsp;
      <a href="#M000033">generate_extraction_info_file_database_level</a>&nbsp;&nbsp;
      <a href="#M000032">generate_extraction_info_file_table_level</a>&nbsp;&nbsp;
      <a href="#M000029">get_table_data_to_csv</a>&nbsp;&nbsp;
      <a href="#M000028">read_extract_file</a>&nbsp;&nbsp;
      <a href="#M000027">write_extract_options_to_a_file</a>&nbsp;&nbsp;
      </div>
    </div>

  </div>


    <!-- if includes -->

    <div id="section">





      


    <!-- if method_list -->
    <div id="methods">
      <h3 class="section-bar">Public Instance methods</h3>

      <div id="method-M000030" class="method-detail">
        <a name="M000030"></a>

        <div class="method-heading">
          <a href="extraction_rb.src/M000030.html" target="Code" class="method-signature"
            onclick="popupCode('extraction_rb.src/M000030.html');return false;">
          <span class="method-name">extract_tables</span><span class="method-args">(all_table_names,new_connection)</span>
          </a>
        </div>
      
        <div class="method-description">
        </div>
      </div>

      <div id="method-M000031" class="method-detail">
        <a name="M000031"></a>

        <div class="method-heading">
          <a href="extraction_rb.src/M000031.html" target="Code" class="method-signature"
            onclick="popupCode('extraction_rb.src/M000031.html');return false;">
          <span class="method-name">extract_tables_to_fixed_width</span><span class="method-args">(all_table_names,new_connection,width)</span>
          </a>
        </div>
      
        <div class="method-description">
        </div>
      </div>

      <div id="method-M000033" class="method-detail">
        <a name="M000033"></a>

        <div class="method-heading">
          <a href="extraction_rb.src/M000033.html" target="Code" class="method-signature"
            onclick="popupCode('extraction_rb.src/M000033.html');return false;">
          <span class="method-name">generate_extraction_info_file_database_level</span><span class="method-args">(database,total_tables,total_time_for_extraction)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
This method generates a single statistics file for the entire database.
This includes number of tables extracted and time taken for it.
</p>
        </div>
      </div>

      <div id="method-M000032" class="method-detail">
        <a name="M000032"></a>

        <div class="method-heading">
          <a href="extraction_rb.src/M000032.html" target="Code" class="method-signature"
            onclick="popupCode('extraction_rb.src/M000032.html');return false;">
          <span class="method-name">generate_extraction_info_file_table_level</span><span class="method-args">(connection,names,start_time,end_time)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
This method generates a different statistics file for each table.Currently
they are including the time stats. Much advanced features like Benchmarking
a table for speed of extraction are in the pipeline right now. This also
shows extraction time per record.
</p>
        </div>
      </div>

      <div id="method-M000029" class="method-detail">
        <a name="M000029"></a>

        <div class="method-heading">
          <a href="extraction_rb.src/M000029.html" target="Code" class="method-signature"
            onclick="popupCode('extraction_rb.src/M000029.html');return false;">
          <span class="method-name">get_table_data_to_csv</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
This method is the central clearing house of the extraction process. This
one calls both the connection and extraction methods.
</p>
        </div>
      </div>

      <div id="method-M000028" class="method-detail">
        <a name="M000028"></a>

        <div class="method-heading">
          <a href="extraction_rb.src/M000028.html" target="Code" class="method-signature"
            onclick="popupCode('extraction_rb.src/M000028.html');return false;">
          <span class="method-name">read_extract_file</span><span class="method-args">()</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
This method reads the config file and extracts all the options. These
options include the source database and other connection parameter. This
method will be merged with extract_connection_options generic method.
</p>
        </div>
      </div>

      <div id="method-M000027" class="method-detail">
        <a name="M000027"></a>

        <div class="method-heading">
          <a href="extraction_rb.src/M000027.html" target="Code" class="method-signature"
            onclick="popupCode('extraction_rb.src/M000027.html');return false;">
          <span class="method-name">write_extract_options_to_a_file</span><span class="method-args">(process_option)</span>
          </a>
        </div>
      
        <div class="method-description">
          <p>
These methods will be used in the extraction phase. This method
prepopulates the config templates for both the extract and loading process
based on the parameter sent.
</p>
        </div>
      </div>


    </div>


  </div>


<div id="validator-badges">
  <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
</div>

</body>
</html>